package com.example.carproviderbackstage.service.impl.dl.admin;

import com.alibaba.dubbo.config.annotation.Service;
import com.example.carinterface.service.dl.admin.CommentService;
import com.example.carinterface.utils.ResultJson;
import com.example.carproviderbackstage.mapper.dl.admin.CommentMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
import java.util.Map;

@Service
public class CommentServiceImpl implements CommentService {

    @Autowired
    private CommentMapper commentMapper;
    @Override
    @Transactional
    public ResultJson<List<Map<String, Object>>> findComment(Map<String, Object> map) {

        ResultJson<List<Map<String, Object>>> resultJson = new ResultJson<>();
        List<Map<String, Object>> list =  commentMapper.findComment(map);
        resultJson.setSuccess("查询成功", list);

        return resultJson;
    }
}
